<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>v-once的使用方法</title>
</head>
<body>
    <!-- v-once 表示数据填充数据后不能实现数据的更改 -->
    <div class="app">
        <div>{{name}}</div>
        <div v-once>{{msg}}</div>
    </div>
    <script type="text/javascript" src="./js/vue.js"></script>
    <script type="text/javascript">
        var xm = new Vue({
            el: '.app',
            data: {
                name: '你好',
                msg: 'hahah'
            }
        })
    </script>
</body>

</html>